_-prefix the nonstatic pixops_... functions. (#142233, Morten Welinder)
authorMatthias Clasen <mclasen@redhat.com>
Mon, 10 May 2004 19:42:59 +0000 (19:42 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Mon, 10 May 2004 19:42:59 +0000 (19:42 +0000)
2004-05-10  Matthias Clasen  <mclasen@redhat.com>

* pixops/timescale.c:
* pixops/pixops.c:
* pixops/pixops.h:
* gdk-pixbuf-scale.c: _-prefix the nonstatic pixops_...
functions.  (#142233, Morten Welinder)

gdk-pixbuf/ChangeLog
gdk-pixbuf/gdk-pixbuf-scale.c
gdk-pixbuf/pixops/pixops.c
gdk-pixbuf/pixops/pixops.h
gdk-pixbuf/pixops/timescale.c

index d27e7dee8dea9a356aec7cc7a414a80aadfd679e..59c86dc4acda3df200fd1b384ce98e3b4f7764dc 100644 (file)
@@ -1,3 +1,13 @@
+2004-05-10  Matthias Clasen  <mclasen@redhat.com>
+
+       Merged from 2.4:
+       
+       * pixops/timescale.c: 
+       * pixops/pixops.c: 
+       * pixops/pixops.h: 
+       * gdk-pixbuf-scale.c: _-prefix the nonstatic pixops_... 
+       functions.  (#142233, Morten Welinder)
+       
 Wed May  5 23:09:48 2004  Matthias Clasen  <maclas@gmx.de>
 
        * gdk-pixbuf-io.h (GdkPixbufFormatFlags): New format flag
index b23dc2fef732dbf999652551b20f6c1ba0eb1ff4..33a0199178a2265a0e4a4e3500a852103e506fa0 100644 (file)
@@ -72,13 +72,13 @@ gdk_pixbuf_scale (const GdkPixbuf *src,
   offset_x = floor (offset_x + 0.5);
   offset_y = floor (offset_y + 0.5);
   
-  pixops_scale (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
-               dest_x - offset_x, dest_y - offset_y, 
-               dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
-               dest->rowstride, dest->n_channels, dest->has_alpha,
-               src->pixels, src->width, src->height,
-               src->rowstride, src->n_channels, src->has_alpha,
-               scale_x, scale_y, (PixopsInterpType)interp_type);
+  _pixops_scale (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
+                dest_x - offset_x, dest_y - offset_y, 
+                dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
+                dest->rowstride, dest->n_channels, dest->has_alpha,
+                src->pixels, src->width, src->height,
+                src->rowstride, src->n_channels, src->has_alpha,
+                scale_x, scale_y, (PixopsInterpType)interp_type);
 }
 
 /**
@@ -123,13 +123,13 @@ gdk_pixbuf_composite (const GdkPixbuf *src,
 
   offset_x = floor (offset_x + 0.5);
   offset_y = floor (offset_y + 0.5);
-  pixops_composite (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
-                   dest_x - offset_x, dest_y - offset_y, 
-                   dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
-                   dest->rowstride, dest->n_channels, dest->has_alpha,
-                   src->pixels, src->width, src->height,
-                   src->rowstride, src->n_channels, src->has_alpha,
-                   scale_x, scale_y, (PixopsInterpType)interp_type, overall_alpha);
+  _pixops_composite (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
+                    dest_x - offset_x, dest_y - offset_y, 
+                    dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
+                    dest->rowstride, dest->n_channels, dest->has_alpha,
+                    src->pixels, src->width, src->height,
+                    src->rowstride, src->n_channels, src->has_alpha,
+                    scale_x, scale_y, (PixopsInterpType)interp_type, overall_alpha);
 }
 
 /**
@@ -191,14 +191,14 @@ gdk_pixbuf_composite_color (const GdkPixbuf *src,
   offset_x = floor (offset_x + 0.5);
   offset_y = floor (offset_y + 0.5);
   
-  pixops_composite_color (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
-                         dest_x - offset_x, dest_y - offset_y, 
-                         dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
-                         dest->rowstride, dest->n_channels, dest->has_alpha,
-                         src->pixels, src->width, src->height,
-                         src->rowstride, src->n_channels, src->has_alpha,
-                         scale_x, scale_y, (PixopsInterpType)interp_type, overall_alpha, check_x, check_y,
-                         check_size, color1, color2);
+  _pixops_composite_color (dest->pixels + dest_y * dest->rowstride + dest_x * dest->n_channels,
+                          dest_x - offset_x, dest_y - offset_y, 
+                          dest_x + dest_width - offset_x, dest_y + dest_height - offset_y,
+                          dest->rowstride, dest->n_channels, dest->has_alpha,
+                          src->pixels, src->width, src->height,
+                          src->rowstride, src->n_channels, src->has_alpha,
+                          scale_x, scale_y, (PixopsInterpType)interp_type, overall_alpha, check_x, check_y,
+                          check_size, color1, color2);
 }
 
 /**
index 633b5bc0b7f03efd07ab864cb0632f5eecfc5c26..e4a086c2f04326a73e348332b5e9625a6f2cc4c5 100644 (file)
@@ -1357,29 +1357,29 @@ make_weights (PixopsFilter     *filter,
 }
 
 void
-pixops_composite_color (guchar         *dest_buf,
-                       int             render_x0,
-                       int             render_y0,
-                       int             render_x1,
-                       int             render_y1,
-                       int             dest_rowstride,
-                       int             dest_channels,
-                       gboolean        dest_has_alpha,
-                       const guchar   *src_buf,
-                       int             src_width,
-                       int             src_height,
-                       int             src_rowstride,
-                       int             src_channels,
-                       gboolean        src_has_alpha,
-                       double          scale_x,
-                       double          scale_y,
-                       PixopsInterpType   interp_type,
-                       int             overall_alpha,
-                       int             check_x,
-                       int             check_y,
-                       int             check_size,
-                       guint32         color1,
-                       guint32         color2)
+_pixops_composite_color (guchar         *dest_buf,
+                        int             render_x0,
+                        int             render_y0,
+                        int             render_x1,
+                        int             render_y1,
+                        int             dest_rowstride,
+                        int             dest_channels,
+                        gboolean        dest_has_alpha,
+                        const guchar   *src_buf,
+                        int             src_width,
+                        int             src_height,
+                        int             src_rowstride,
+                        int             src_channels,
+                        gboolean        src_has_alpha,
+                        double          scale_x,
+                        double          scale_y,
+                        PixopsInterpType   interp_type,
+                        int             overall_alpha,
+                        int             check_x,
+                        int             check_y,
+                        int             check_size,
+                        guint32         color1,
+                        guint32         color2)
 {
   PixopsFilter filter;
   PixopsLineFunc line_func;
@@ -1396,10 +1396,10 @@ pixops_composite_color (guchar         *dest_buf,
 
   if (!src_has_alpha && overall_alpha == 255)
     {
-      pixops_scale (dest_buf, render_x0, render_y0, render_x1, render_y1,
-                   dest_rowstride, dest_channels, dest_has_alpha,
-                   src_buf, src_width, src_height, src_rowstride, src_channels,
-                   src_has_alpha, scale_x, scale_y, interp_type);
+      _pixops_scale (dest_buf, render_x0, render_y0, render_x1, render_y1,
+                    dest_rowstride, dest_channels, dest_has_alpha,
+                    src_buf, src_width, src_height, src_rowstride, src_channels,
+                    src_has_alpha, scale_x, scale_y, interp_type);
       return;
     }
 
@@ -1435,7 +1435,7 @@ pixops_composite_color (guchar         *dest_buf,
 }
 
 /**
- * pixops_composite:
+ * _pixops_composite:
  * @dest_buf: pointer to location to store result
  * @render_x0: x0 of region of scaled source to store into @dest_buf
  * @render_y0: y0 of region of scaled source to store into @dest_buf
@@ -1459,24 +1459,24 @@ pixops_composite_color (guchar         *dest_buf,
  * of the result into the destination buffer.
  **/
 void
-pixops_composite (guchar        *dest_buf,
-                 int            render_x0,
-                 int            render_y0,
-                 int            render_x1,
-                 int            render_y1,
-                 int            dest_rowstride,
-                 int            dest_channels,
-                 gboolean       dest_has_alpha,
-                 const guchar  *src_buf,
-                 int            src_width,
-                 int            src_height,
-                 int            src_rowstride,
-                 int            src_channels,
-                 gboolean       src_has_alpha,
-                 double         scale_x,
-                 double         scale_y,
-                 PixopsInterpType  interp_type,
-                 int            overall_alpha)
+_pixops_composite (guchar        *dest_buf,
+                  int            render_x0,
+                  int            render_y0,
+                  int            render_x1,
+                  int            render_y1,
+                  int            dest_rowstride,
+                  int            dest_channels,
+                  gboolean       dest_has_alpha,
+                  const guchar  *src_buf,
+                  int            src_width,
+                  int            src_height,
+                  int            src_rowstride,
+                  int            src_channels,
+                  gboolean       src_has_alpha,
+                  double         scale_x,
+                  double         scale_y,
+                  PixopsInterpType  interp_type,
+                  int            overall_alpha)
 {
   PixopsFilter filter;
   PixopsLineFunc line_func;
@@ -1493,10 +1493,10 @@ pixops_composite (guchar        *dest_buf,
 
   if (!src_has_alpha && overall_alpha == 255)
     {
-      pixops_scale (dest_buf, render_x0, render_y0, render_x1, render_y1,
-                   dest_rowstride, dest_channels, dest_has_alpha,
-                   src_buf, src_width, src_height, src_rowstride, src_channels,
-                   src_has_alpha, scale_x, scale_y, interp_type);
+      _pixops_scale (dest_buf, render_x0, render_y0, render_x1, render_y1,
+                    dest_rowstride, dest_channels, dest_has_alpha,
+                    src_buf, src_width, src_height, src_rowstride, src_channels,
+                    src_has_alpha, scale_x, scale_y, interp_type);
       return;
     }
 
@@ -1536,23 +1536,23 @@ pixops_composite (guchar        *dest_buf,
 }
 
 void
-pixops_scale (guchar        *dest_buf,
-             int            render_x0,
-             int            render_y0,
-             int            render_x1,
-             int            render_y1,
-             int            dest_rowstride,
-             int            dest_channels,
-             gboolean       dest_has_alpha,
-             const guchar  *src_buf,
-             int            src_width,
-             int            src_height,
-             int            src_rowstride,
-             int            src_channels,
-             gboolean       src_has_alpha,
-             double         scale_x,
-             double         scale_y,
-             PixopsInterpType  interp_type)
+_pixops_scale (guchar        *dest_buf,
+              int            render_x0,
+              int            render_y0,
+              int            render_x1,
+              int            render_y1,
+              int            dest_rowstride,
+              int            dest_channels,
+              gboolean       dest_has_alpha,
+              const guchar  *src_buf,
+              int            src_width,
+              int            src_height,
+              int            src_rowstride,
+              int            src_channels,
+              gboolean       src_has_alpha,
+              double         scale_x,
+              double         scale_y,
+              PixopsInterpType  interp_type)
 {
   PixopsFilter filter;
   PixopsLineFunc line_func;
index 15ffb32af93813470243bb62ecdf0c11705e5608..7adf0044e49a608e9df9682a073c4e6485d78740 100644 (file)
@@ -18,24 +18,24 @@ typedef enum {
  * render_x, render_y, render_width, render_height in the new
  * coordinate system into dest_buf starting at 0, 0
  */
-void pixops_composite (guchar         *dest_buf,
-                      int             render_x0,
-                      int             render_y0,
-                      int             render_x1,
-                      int             render_y1,
-                      int             dest_rowstride,
-                      int             dest_channels,
-                      int             dest_has_alpha,
-                      const guchar   *src_buf,
-                      int             src_width,
-                      int             src_height,
-                      int             src_rowstride,
-                      int             src_channels,
-                      int             src_has_alpha,
-                      double          scale_x,
-                      double          scale_y,
-                      PixopsInterpType   interp_type,
-                      int             overall_alpha);
+void _pixops_composite (guchar         *dest_buf,
+                       int             render_x0,
+                       int             render_y0,
+                       int             render_x1,
+                       int             render_y1,
+                       int             dest_rowstride,
+                       int             dest_channels,
+                       int             dest_has_alpha,
+                       const guchar   *src_buf,
+                       int             src_width,
+                       int             src_height,
+                       int             src_rowstride,
+                       int             src_channels,
+                       int             src_has_alpha,
+                       double          scale_x,
+                       double          scale_y,
+                       PixopsInterpType   interp_type,
+                       int             overall_alpha);
 
 /* Scale src_buf from src_width / src_height by factors scale_x, scale_y
  * and composite the portion corresponding to
@@ -43,36 +43,36 @@ void pixops_composite (guchar         *dest_buf,
  * coordinate system against a checkboard with checks of size check_size
  * of the colors color1 and color2 into dest_buf starting at 0, 0
  */
-void pixops_composite_color (guchar         *dest_buf,
-                            int             render_x0,
-                            int             render_y0,
-                            int             render_x1,
-                            int             render_y1,
-                            int             dest_rowstride,
-                            int             dest_channels,
-                            int             dest_has_alpha,
-                            const guchar   *src_buf,
-                            int             src_width,
-                            int             src_height,
-                            int             src_rowstride,
-                            int             src_channels,
-                            int             src_has_alpha,
-                            double          scale_x,
-                            double          scale_y,
-                            PixopsInterpType   interp_type,
-                            int             overall_alpha,
-                            int             check_x,
-                            int             check_y,
-                            int             check_size,
-                            guint32         color1,
-                            guint32         color2);
+void _pixops_composite_color (guchar         *dest_buf,
+                             int             render_x0,
+                             int             render_y0,
+                             int             render_x1,
+                             int             render_y1,
+                             int             dest_rowstride,
+                             int             dest_channels,
+                             int             dest_has_alpha,
+                             const guchar   *src_buf,
+                             int             src_width,
+                             int             src_height,
+                             int             src_rowstride,
+                             int             src_channels,
+                             int             src_has_alpha,
+                             double          scale_x,
+                             double          scale_y,
+                             PixopsInterpType   interp_type,
+                             int             overall_alpha,
+                             int             check_x,
+                             int             check_y,
+                             int             check_size,
+                             guint32         color1,
+                             guint32         color2);
 
 /* Scale src_buf from src_width / src_height by factors scale_x, scale_y
  * and composite the portion corresponding to
  * render_x, render_y, render_width, render_height in the new
  * coordinate system into dest_buf starting at 0, 0
  */
-void pixops_scale     (guchar         *dest_buf,
+void _pixops_scale    (guchar         *dest_buf,
                       int             render_x0,
                       int             render_y0,
                       int             render_x1,
index 94ed3cf13848e893ddb148bde16cafa0c5fca550..03401405d6c0654c63e8e6e1e9cf86f70185521c 100644 (file)
@@ -182,10 +182,10 @@ int main (int argc, char **argv)
                start_timing ();
                for (i = 0; i < ITERS; i++)
                  {
-                   pixops_scale (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
-                                 src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
-                                 (double)dest_width / src_width, (double)dest_height / src_height,
-                                 filter_level);
+                   _pixops_scale (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
+                                  src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
+                                  (double)dest_width / src_width, (double)dest_height / src_height,
+                                  filter_level);
                  }
                scale_times[src_index][dest_index][filter_level] =
                  stop_timing ("   scale\t\t", ITERS, dest_height * dest_width);
@@ -194,10 +194,10 @@ int main (int argc, char **argv)
            start_timing ();
            for (i = 0; i < ITERS; i++)
              {
-               pixops_composite (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
-                             src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
-                             (double)dest_width / src_width, (double)dest_height / src_height,
-                             filter_level, 255);
+               _pixops_composite (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
+                                  src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
+                                  (double)dest_width / src_width, (double)dest_height / src_height,
+                                  filter_level, 255);
              }
            composite_times[src_index][dest_index][filter_level] =
              stop_timing ("   composite\t\t", ITERS, dest_height * dest_width);
@@ -205,10 +205,10 @@ int main (int argc, char **argv)
            start_timing ();
            for (i = 0; i < ITERS; i++)
              {
-               pixops_composite_color (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
-                                       src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
-                                       (double)dest_width / src_width, (double)dest_height / src_height,
-                                       filter_level, 255, 0, 0, 16, 0xaaaaaa, 0x555555);
+               _pixops_composite_color (dest_buf, 0, 0, dest_width, dest_height, dest_rowstride, dest_channels, dest_has_alpha,
+                                        src_buf, src_width, src_height, src_rowstride, src_channels, src_has_alpha,
+                                        (double)dest_width / src_width, (double)dest_height / src_height,
+                                        filter_level, 255, 0, 0, 16, 0xaaaaaa, 0x555555);
              }
            composite_color_times[src_index][dest_index][filter_level] =
              stop_timing ("   composite color\t", ITERS, dest_height * dest_width);